define(['app'], function(app) {
	'use strict';

	var controller = function controller($scope, Statistics_present,$ionicSlideBoxDelegate) {

       $scope.isTable = true;
       $scope.isImage = false;
       $scope.changeTable = function(){
       	$scope.isTable = true;
       	$scope.isImage = false;
       }
        $scope.changeImage = function(){
       	$scope.isTable = false;
       	$scope.isImage = true;
       }
        $scope.init_data=function(){
           Statistics_present.get_statistics('act_id','act_type',function(data){
              $scope.data=data;

           });
        }
        $scope.init_data();

	}

	controller.$inject = ['$scope', 'Statistics_present','$ionicSlideBoxDelegate'];

	return app.registerController("statistics_presentctrl",controller);
});